package com.linkage.lcims.base.po.system;

import java.io.Serializable;
import java.util.Date;
import org.apache.commons.lang.builder.EqualsBuilder;
import org.apache.commons.lang.builder.HashCodeBuilder;
import org.apache.commons.lang.builder.ToStringBuilder;


/** 
 *        @hibernate.class
 *         table="M_ADMIN_LOG"
 *     
*/
@SuppressWarnings("serial")
public class MAdminLog implements Serializable {

    /** identifier field */
    private long serno;

    /** nullable persistent field */
    private String admin;

    /** nullable persistent field */
    private String areano;

    /** nullable persistent field */
    private Integer roleid;

    /** nullable persistent field */
    private Date operatetime;

    /** nullable persistent field */
    private String ipaddress;

    /** nullable persistent field */
    private String funcid;

    /** nullable persistent field */
    private Integer operatetype;

    /** nullable persistent field */
    private String username;

    /** nullable persistent field */
    private Integer clienttype;

    /** nullable persistent field */
    private String note;

    /** full constructor */
    public MAdminLog(long serno, String admin, String areano, Integer roleid, Date operatetime, String ipaddress, String funcid, Integer operatetype, String username, Integer clienttype, String note) {
        this.serno = serno;
        this.admin = admin;
        this.areano = areano;
        this.roleid = roleid;
        this.operatetime = operatetime;
        this.ipaddress = ipaddress;
        this.funcid = funcid;
        this.operatetype = operatetype;
        this.username = username;
        this.clienttype = clienttype;
        this.note = note;
    }

    /** default constructor */
    public MAdminLog() {
    }

    /** minimal constructor */
    public MAdminLog(long serno) {
        this.serno = serno;
    }

    /** 
     *            @hibernate.id
     *             generator-class="assigned"
     *             type="java.math.BigDecimal"
     *             column="serno"
     *         
     */
    public long getSerno() {
        return this.serno;
    }

    public void setSerno(long serno) {
        this.serno = serno;
    }

    /** 
     *            @hibernate.property
     *             column="admin"
     *             length="40"
     *         
     */
    public String getAdmin() {
        return this.admin;
    }

    public void setAdmin(String admin) {
        this.admin = admin;
    }

    /** 
     *            @hibernate.property
     *             column="areano"
     *             length="20"
     *         
     */
    public String getAreano() {
        return this.areano;
    }

    public void setAreano(String areano) {
        this.areano = areano;
    }

    /** 
     *            @hibernate.property
     *             column="roleid"
     *             length="10"
     *         
     */
    public Integer getRoleid() {
        return this.roleid;
    }

    public void setRoleid(Integer roleid) {
        this.roleid = roleid;
    }

    /** 
     *            @hibernate.property
     *             column="operatetime"
     *             length="23"
     *         
     */
    public Date getOperatetime() {
        return this.operatetime;
    }

    public void setOperatetime(Date operatetime) {
        this.operatetime = operatetime;
    }

    /** 
     *            @hibernate.property
     *             column="ipaddress"
     *             length="16"
     *         
     */
    public String getIpaddress() {
        return this.ipaddress;
    }

    public void setIpaddress(String ipaddress) {
        this.ipaddress = ipaddress;
    }

    /** 
     *            @hibernate.property
     *             column="funcid"
     *             length="18"
     *         
     */
    public String getFuncid() {
        return this.funcid;
    }

    public void setFuncid(String funcid) {
        this.funcid = funcid;
    }

    /** 
     *            @hibernate.property
     *             column="operatetype"
     *             length="10"
     *         
     */
    public Integer getOperatetype() {
        return this.operatetype;
    }

    public void setOperatetype(Integer operatetype) {
        this.operatetype = operatetype;
    }

    /** 
     *            @hibernate.property
     *             column="username"
     *             length="40"
     *         
     */
    public String getUsername() {
        return this.username;
    }

    public void setUsername(String username) {
        this.username = username;
    }

    /** 
     *            @hibernate.property
     *             column="clienttype"
     *             length="10"
     *         
     */
    public Integer getClienttype() {
        return this.clienttype;
    }

    public void setClienttype(Integer clienttype) {
        this.clienttype = clienttype;
    }

    /** 
     *            @hibernate.property
     *             column="note"
     *             length="255"
     *         
     */
    public String getNote() {
        return this.note;
    }

    public void setNote(String note) {
        this.note = note;
    }

    public String toString() {
        return new ToStringBuilder(this)
            .append("serno", getSerno())
            .toString();
    }

    public boolean equals(Object other) {
        if ( (this == other ) ) return true;
        if ( !(other instanceof MAdminLog) ) return false;
        MAdminLog castOther = (MAdminLog) other;
        return new EqualsBuilder()
            .append(this.getSerno(), castOther.getSerno())
            .isEquals();
    }

    public int hashCode() {
        return new HashCodeBuilder()
            .append(getSerno())
            .toHashCode();
    }

}
